<div class="container">
	<div class="row clearfix">
		<ol class="breadcrumb forum-breadcrumb">
			<li><a href="?c=forum"><span class="glyphicon glyphicon-home"></span> 首页</a></li>
			<li class="active"><span class="glyphicon glyphicon-edit"></span> 开通频道</li>
		</ol>
	</div>
</div>
<div class="container">
	<div class="forum-add">
		<div class="row clearfix">
			<div class="col-md-12 column">
				<h3><span class="glyphicon glyphicon-edit"></span> 开通频道</h3>
				<hr class="solid">
				<div class="col-md-11 column">
					<form class="form-horizontal" id="do_forum_add" action="javascript:do_forum_add()">
						<fieldset>
							<!-- Text input-->
							<div class="form-group">
								<label class="col-md-2 control-label">名称</label>  
								<div class="col-md-7">
									<input name="name" type="text" placeholder="某某频道" class="form-control input-md" required="">
								</div>
							</div>
							<!-- Text input-->
							<div class="form-group">
								<label class="col-md-2 control-label">描述</label>  
								<div class="col-md-7">
									<div class="checkbox"><label><input name="auto_intro" type="checkbox" onclick="check_auto_intro()" checked="checked"> 自动更新 </label></div>
									<textarea id="forum_intro" name="intro" type="text" rows="3" placeholder="简单的介绍" class="form-control input-md" style="margin-top:10px;display:none"></textarea>
								</div>
							</div>
							<!-- Text input-->
							<div class="form-group">
								<label class="col-md-2 control-label">图标URL</label>  
								<div class="col-md-2">
								<div class="checkbox"><label><input name="auto_bg_url" type="checkbox" onclick="check_auto_bg_url()" checked="checked"> 自动更新 </label></div>
								</div>
								<div class="col-md-5">
									<input id="forum_bg_url" name="background_url" type="text" placeholder="http://xxx/xxx/xx.jpg" class="form-control input-md" style="display:none">
								</div>
							</div>
							<div class="form-group">
								<label class="col-md-2 control-label">类型</label>  
								<div class="col-md-7">
									<?php require_once('forum_ext/forum_ext.php'); ?>
									<?php foreach ($forum_ext as $key => $f_e) { ?>
									<label class="radio-inline"> <input type="radio" name="ext" value="<?php echo $key ?>" <?php echo $f_e['checked'] ?>> <?php echo $f_e['name'] ?> </label>
									<?php } ?>
								</div>
							</div>
							<!-- token -->
							<input type="hidden" name="token" value="<?php echo get_token() ?>"/>
							<!-- Button -->
							<div class="form-group">
								<label class="col-md-2 control-label"></label>
								<div class="col-md-2">
									<button class="btn btn-primary btn-block <?php if (empty($_SESSION['auth'])) echo "disabled"; ?>">开通</button>
								</div>
								<div class="col-md-5">
									<?php if (empty($_SESSION['auth'])) { ?>
									<a class="btn btn-success btn-block" type="button" href="javascript:jump_to_login('?c=forum&a=forum_add')">登录后开通</a>
									<?php } else { ?>
									<a class="btn btn-success btn-block" type="button" href="javascript:pay_forum_add()">付费开通</a>
									<?php } ?>
								</div>
							</div>
						</fieldset>
					</form>	


				</div>
			</div>
		</div>
	</div>
</div>
<script type="text/javascript">

$(document).ready(function(){
		$('li#get_forum').addClass('active');
		});

</script>
